//
//  RecommendModel.m
//  LT
//
//  Created by dllo on 16/5/18.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "RecommendModel.h"
#import "DisSubTwoModel.h"
#import "CarouselModel.h"
#import "DisTwoModel.h"
#import "ThirdLModel.h"
#import "NextFourModel.h"

@implementation RecommendModel


-(void)setValue:(id)value forUndefinedKey:(NSString *)key{
    
    
}

//轮播图
-(void)setSlide:(NSMutableArray *)slide{
    _slide = slide;
    NSMutableArray *slideArray = [NSMutableArray array];
    for (NSMutableDictionary *dic in slide) {
        CarouselModel *carouse = [[CarouselModel alloc]init];
        [carouse setValuesForKeysWithDictionary:dic];
        [slideArray addObject:carouse];
    }
    
    _slide = [NSMutableArray arrayWithArray:slideArray];
}

//发现下一站
-(void)setSubject:(NSMutableArray *)subject{
    _subject = subject;
    NSMutableArray *array = [NSMutableArray array];
    for (NSDictionary *dic in subject) {
        NextFourModel *nextModel = [[NextFourModel alloc]init];
        [nextModel setValuesForKeysWithDictionary:dic];
        [array addObject:nextModel];
        
    }
    _subject = [NSMutableArray arrayWithArray:array];
    
}

//抢特价折扣大图
-(void)setDiscount_subject:(NSMutableArray *)discount_subject{
    _discount_subject = discount_subject;
    NSMutableArray *array = [NSMutableArray array];
    for (NSDictionary *dic in discount_subject) {
        
        DisSubTwoModel *disModel = [[DisSubTwoModel alloc]init];
        [disModel setValuesForKeysWithDictionary:dic];
        [array addObject:disModel];
        
    }
    _discount_subject = [NSMutableArray arrayWithArray:array];
    
}

//抢特价折扣小图
-(void)setDiscount:(NSMutableArray *)discount{
    _discount = discount;
    NSMutableArray *countArray = [NSMutableArray array];
    for (NSDictionary *dic in discount) {
        DisTwoModel *disModel = [[DisTwoModel alloc]init];
        //kvc
        [disModel setValuesForKeysWithDictionary:dic];
        [countArray addObject:disModel];
        
    }
    _discount = [NSMutableArray arrayWithArray:countArray];
    
    
}






@end
